// 第三方应用管理
export const EnterpriseCertificateThead = [
  // {
  //   type: 'selection',
  //   width: 60,
  //   align: 'center'
  // },
  {
    title: '证件类别',
    key: 'documentType',
    minWidth: 150,
    render: (h, params) => {
      let row = params.row
      let text = row.documentType
      if (row.isWarn !== 0) {
        return h('div', {
          class: ''
        }, [
          h('span', {
            class: 'ivu-icon ivu-icon-ios-text text-error font-18 mr-10'
          }, ''),
          h('span', text)
        ])
      } else {
        return h('span', text)
      }
    }
  },
  {
    title: '证件名称',
    key: 'documentName',
    minWidth: 150
  },
  {
    title: '办证机构',
    key: 'unit',
    minWidth: 150
  },
  {
    title: '证件开始时间',
    key: 'startTime',
    render: (h, params) => {
      let row = params.row
      let times = ''
      if (row.startTime) {
        times = row.startTime.slice(0, 10).replace(/T/g, ' ')
      }
      return h('span', times)
    },
    minWidth: 150
  },
  {
    title: '证件结束时间',
    key: 'endTime',
    render: (h, params) => {
      let row = params.row
      let times = ''
      if (row.endTime) {
        times = row.endTime.slice(0, 10).replace(/T/g, ' ')
      }
      return h('span', times)
    },
    minWidth: 150
  },
  {
    title: '储存位置',
    key: 'location',
    minWidth: 150
  },
  {
    title: '负责人',
    key: 'leader',
    minWidth: 150
  },  
  {
    title: '备注',
    key: 'remark',
    minWidth: 150
  },
  {
    title: '附件',
    key: 'fileName',
    slot: 'fileName',
    minWidth: 300
  },
  {
    title: '操作',
    width: 240,
    align: 'center',
    key: 'action',
    slot: 'action',
    fixed: 'right'
  }
]
